package treeset;

import java.util.TreeSet;

/**
 * Created by 5406160@qq.com on LiBoWen 李博闻.
 *
 * @ClassName : TreeSetDemo1
 * @Author : 54061
 * @Date: 2022/2/9 18:12
 */
public class TreeSetDemo1 {
    public static void main(String[] args) {
        TreeSet<Student> ts = new TreeSet<>();

        System.out.println("ts = " + ts);

        //添加学生对象
        ts.add(new Student("张三",17));
        ts.add(new Student("李四",15));
        ts.add(new Student("王五",19));

        System.out.println("ts = " + ts);
    }
}
